<template>
  <div class="freediv" :style="style" ref="mainElement">
    <slot></slot>
  </div>
</template>
<script setup>
import {onMounted, ref} from "vue";
import {useDraggable} from "@vueuse/core";


let mainElement =ref(null)
let isdown =ref(false);
let {x,y,style}=useDraggable(mainElement,{
  initialValue: { x: 40, y: 40 },
})
onMounted(()=>{

})
</script>
<style scoped>
.freediv{
  position: fixed;
  width: 100px;
  height: 100px;
  z-index: 999;
}
</style>